<?php

function showPID()
{
   $pid = posix_getpid();
   fprintf(STDOUT,"pid=%d,ppid=%d,pgid=%d,sid=%d\n",$pid,posix_getppid(),posix_getpgid($pid),posix_getsid($pid));
}

$pid = pcntl_fork();
showPID();
while (1){
    sleep(1);
}
